Skip to content

Fix system df to count content blobs and deduplicate shared storage#1555

Open
realrajaryan wants to merge 1 commit into
apple:mainfrom
realrajaryan:fix/system-df-disk-usage
Open

Fix system df to count content blobs and deduplicate shared storage#1555
realrajaryan wants to merge 1 commit into
apple:mainfrom
realrajaryan:fix/system-df-disk-usage

Conversation

@realrajaryan
Copy link
Copy Markdown
Member

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation update

Motivation and Context

This PR fixes system df to report actual on-disk allocated bytes (content blobs + snapshots) instead of summing per-image snapshot sizes. Orphaned blobs are now included as reclaimable, and storage shared across tags is no longer double counted. Also consolidates three identical calculateDirectorySize implementations into a shared FileManager.allocatedSize(of:) extension.

Testing

  • Tested locally
  • Added/updated tests
  • Added/updated docs

@realrajaryan realrajaryan force-pushed the fix/system-df-disk-usage branch from 1dca65d to c00c1cf Compare May 14, 2026 22:22
@github-actions
Copy link
Copy Markdown

Code Coverage

Tier Line Coverage
Unit 34.04%
Integration 20.44%
Combined 53.9%

@jglogan jglogan self-requested a review May 18, 2026 17:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: container system df omits image content blobs from image size and reclaimable bytes

2 participants